<template>
	<Breadcrumb>
		<BreadCrumbItem v-for="item in currentPath" :to="item" :key="item.name">{{ itemTitle(item) }}</BreadCrumbItem>
	</Breadcrumb>
</template>

<script lang="ts">
	import { Component, Vue, Inject, Prop } from "vue-property-decorator";
	import AppBase from "../core/utils/AppBase";
	@Component
	export default class Breadcrumb extends AppBase {
		name = "breadcrumbNav";
		@Prop({ type: Array }) currentPath!: Array<any>;
		itemTitle(item: any) {
			return this.L(item.meta.title);
		}
	}
</script>